<template>
	<view :style="themeColor">
		<view class="page">
			<view
				class="flex flex-direction flex-wrap align-stretch justify-center benben-position-layout flex payment_flex_0"
				:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }"
			>
				<view class='flex flex-wrap align-stretch justify-between payment_fd0_0'>
					<view
						class='flex flex-wrap align-center payment_fd0_0_c0'
						@tap.stop="handleJumpDiy"
						data-type="back"
						data-url="1"
					>
						<text class='fu-iconfont2  payment_fd0_0_c0_c0'>&#xe794;</text>
					</view>
					<view class='flex flex-wrap align-center'>
						<text
							class='payment_fd0_0_c1_c0'
							style="font-family: Alimama DongFangDaKai, Alimama DongFangDaKai;"
						>设置支付密码</text>
					</view>
					<view class='flex align-center justify-end payment_fd0_0_c2'>
					</view>
				</view>

			</view>
			<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
			<!---修改支付密码第一步flex布局开始-->
			<view class="flex flex-direction flex-wrap align-center benben-flex-layout">
				<text class='payment_fd1_0'>请输入支付密码</text>
				<benben-digital-password
					:box-num='6'
					mode='password'
					class-name='flex flex align-center justify-center payment_fd1_1'
					v-model="oldPayPwd"
					:init-open.sync="xianshi"
				>
					<template #default="{ content, active, index }">
						<view
							:key="index"
							v-if="active"
							class="flex align-center justify-center active-digital-password payment_flex_password_active_fd1_1"
						>
							{{ content }}
						</view>
						<view
							:key="index"
							v-else
							class="flex align-center justify-center payment_flex_password_active_fd1_1"
						>
							{{ content }}
						</view>
					</template>
				</benben-digital-password>
				<button
					class='payment_fd1_2'
					@tap.stop="checkCodeFunc()"
				>下一步</button>
			</view>

			<!---修改支付密码第一步flex布局结束-->


		</view>
	</view>
</template>
<script>
	import { validate } from '@/common/utils/validate.js'
	export default {
		components: {},


		data() {
			return { "oldPayPwd": "", "xianshi": true };
		},
		computed: {
			themeColor() {
				return this.$store.getters.themeColor
			},

		},
		watch: {},
		onLoad(options) {

		},
		onUnload() {

		},
		onReady() {

		},
		onShow() {

		},
		onHide() {

		},
		onResize() {

		},
		onPullDownRefresh() {

		},
		onReachBottom(e) {

		},
		onPageScroll(e) {

		},
		methods: {
			//校验验证码
			checkCodeFunc() {
				if (!validate(this.oldPayPwd, 'require')) {
					this.$message.info('请输入支付密码');
					return false;
				}
				this.$urouter.navigateTo(`/pages/ddgl/paymentPassword/paymentPassword?pwd=${this.oldPayPwd}`);
			}
		}
	};
</script>
<style
	lang="scss"
	scoped
>
	.page {
		width: 100vw;
		overflow-x: hidden;
		min-height: calc(100vh - var(--window-bottom));
		background: #fff;
		background-size: 100% auto;
	}

	.payment_flex_0 {
		background: #fff;
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto !important;
	}

	.payment_fd0_0_c2 {
		padding: 0rpx 0rpx 0rpx 0rpx;
		width: 100rpx;
	}

	.payment_fd0_0_c1_c0 {
		color: #000000;
		font-size: 36rpx;
		font-weight: 500;
		line-height: 50rpx;
	}

	.payment_fd0_0_c0_c0 {
		font-size: 36rpx;
		font-weight: 400;
		color: #333;
	}

	.payment_fd0_0_c0 {
		width: 100rpx;
	}

	.payment_fd0_0 {
		padding: 0rpx 32rpx 0rpx 32rpx;
		line-height: 88rpx;
	}

	.payment_fd1_2 {
		background: var(--benbenbgColor7);
		border-radius: 44rpx 44rpx 44rpx 44rpx;
		font-size: 32rpx;
		color: var(--benbenFontColor3);
		width: 610rpx;
		height: 88rpx;
		line-height: 88rpx;
		margin: 88rpx 0rpx 0rpx 0rpx;
	}

	.payment_flex_password_active_fd1_1 {
		border: 1px solid var(--benbenbdColor4);
		width: 100rpx;
		height: 100rpx;
	}

	::v-deep .payment_fd1_1 {
		width: 750rpx;
		height: 160rpx;
		margin: 24rpx 0rpx 24rpx 0rpx;
	}

	.payment_fd1_0 {
		font-size: 36rpx;
		font-weight: 700;
		color: #333333;
		margin: 208rpx 0rpx 20rpx 0rpx;
		line-height: 50rpx;
	}
</style>